<?php e($javascript->codeBlock('$(document).ready(function(){$("#the-table").tableSorter();});'));?>
<div id="post-admin">
	
	<div class="action-buttons">
		<?php e($html->link('Add new feed', '/admin/feeds/add', array('class'=>'add')));?>
	</div>
	
	<table id="the-table">
		<caption>Feeds on <?php e($sitename);?></caption>
		<colgroup>
			<col id="id" />
			<col id="name" />
			<col id="url" />
			<col id="published" />
			<col id="actions" />
		</colgroup>
		<thead>
			<tr>
				<th scope="col">Feed ID</th>
				<th scope="col">Feed Title</th>
				<th scope="col">Feed URL</th>
				<th scope="col">Published?</th>
				<th scope="col">Actions</th>
			</tr>
		</thead>
		<tbody>
			<?php $row = 0; ?>
			<?php foreach ($feeds as $feed) : ?>
			<tr class="<?php ($row % 2 ? e('even') : e('odd'));?>" id="feed-<?php e($feed['Feed']['id']);?>">
				<td><?php e($feed['Feed']['id']);?></td>
				<td><?php e($feed['Feed']['feed_name']);?></td>
				<td><?php e($feed['Feed']['feed_url']);?></td>
				<td><?php e($feed['Feed']['published'] == 0 ? e('No') : e('Yes'));?></td>
				<td>
					<ul>
						<li><?php e($html->link('Edit', '/admin/feeds/edit/' . $feed['Feed']['id'], array('class'=>'edit')));?></li>
						<li><?php e($html->link('Delete', '/admin/feeds/delete/' . $feed['Feed']['id'], array('class'=>'delete', 'rel'=> $feed['Feed']['id']),'Are you sure you wish to delete feed ' . $feed['Feed']['feed_name']));?></li>
					</ul>
				</td>
			</tr>
			<?php $row++; ?>
			<?php endforeach; ?>
		</tbody>
	</table>
</div>

<div id="paginate">
	<span class="previous">
		<?php e($paginator->prev('<< Previous', null, null, array('class' => 'disabled'))); ?>
	</span>
	<span class="next">
		<?php e($paginator->next('Next >>', null, null, array('class' => 'disabled'))); ?>
	</span>
	<br style="clear" />
</div>